<# # It is recommended to test the script on a local machine for its purpose and effects. # ManageEngine Endpoint Central will not be responsible for any # damage/loss to the data/setup based on the behavior of the script. # Description: Script is designed To turn on hibernate mode # Configuration Type - COMPUTER # Refer : https://www.tenforums.com/tutorials/2859-enable-disable-hibernate-windows-10-a.html #> # Disable hibernation $disableHibernation = powercfg /hibernate on # Check if the command was successful or not if ($LastExitCode -eq 0) { Write-Host "Hibernation has been Enabled successfully." } else { Write-Host "Error: Failed to Enable hibernation. Exit code: $LastExitCode" }